package edu.xhu.api.behavior;

import edu.xhu.api.behavior.fallback.BehaviorClientFallback;
import edu.xhu.model.behavior.dto.AddCommentDto;
import edu.xhu.model.behavior.dto.RootCommentDto;
import edu.xhu.model.behavior.dto.SonCommentDto;
import edu.xhu.model.behavior.pojos.BiliUserChatDetail;
import edu.xhu.model.common.dtos.ResponseResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(value = "behavior-service", fallback = BehaviorClientFallback.class)
public interface BehaviorClient {
    @PostMapping("/comment/rootComment")
    @ApiOperation("api-返回视频的热度评论")
    ResponseResult<?> queryRootCommentsByVideoIds(@RequestBody RootCommentDto rootCommentDto);

    @PostMapping("/comment/rootCommentIdsByVideoId")
    @ApiOperation("api-根据videoId返回所有根评论id")
    public ResponseResult<?> queryRootCommentIdsByVideoId(@RequestBody RootCommentDto rootCommentDto);

    @PostMapping("/comment/rootCommentByCommentIds")
    @ApiOperation("api-根据commentIds返回根评论")
    ResponseResult<?> queryRootCommentsByCommentIds(@RequestBody RootCommentDto rootCommentDto);

    @PostMapping("/comment/sonComment")
    @ApiOperation("api-返回根评的所有子评")
    ResponseResult<?> querySonCommentsByRootIds(@RequestBody SonCommentDto sonCommentDto);

    @PostMapping("/comment/addComment")
    @ApiOperation("api-添加评论api")
    ResponseResult<?> addComment(@RequestBody AddCommentDto addCommentDto);
}
